shortcut.add("Ctrl+S", function() {
});

shortcut.add("Ctrl+Alt+N", function() {
});

shortcut.add("Ctrl+Shift+S", function() {
});

shortcut.add("Ctrl+Tab", function() {
});

shortcut.add("Ctrl+A", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.selectAll(activeCodeMirror);
});
shortcut.add("Ctrl+D", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.deleteLine(activeCodeMirror);
});
shortcut.add("Ctrl+Z", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.undo(activeCodeMirror);
});
shortcut.add("Shift+Ctrl+Z", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.redo(activeCodeMirror);
});
shortcut.add("Ctrl+Home", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.goDocStart(activeCodeMirror);
});
shortcut.add("Alt+Up", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.goDocStart(activeCodeMirror);
});
shortcut.add("Ctrl+End", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.goDocEnd(activeCodeMirror);
});
shortcut.add("Ctrl+Down", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.goDocEnd(activeCodeMirror);
});
shortcut.add("Ctrl+Left", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.goWordLeft(activeCodeMirror);
});
shortcut.add("Ctrl+Right", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.goWordRight(activeCodeMirror);
});
shortcut.add("Alt+Left", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.goLineStart(activeCodeMirror);
});
shortcut.add("Alt+Right", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.goLineEnd(activeCodeMirror);
});
shortcut.add("Ctrl+Backspace", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.delWordLeft(activeCodeMirror);
});
shortcut.add("Ctrl+Delete", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.delWordRight(activeCodeMirror);
});
shortcut.add("Ctrl+S", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.save(activeCodeMirror);
});
shortcut.add("Ctrl+F", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.find(activeCodeMirror);
});
shortcut.add("Ctrl+K", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.findNext(activeCodeMirror);
});
shortcut.add("Shift+Ctrl+K", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.findPrev(activeCodeMirror);
});
shortcut.add("Alt+Shift+F", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.replace(activeCodeMirror);
});
shortcut.add("Ctrl+[", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.indentLess(activeCodeMirror);
});
shortcut.add("Ctrl+]", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.indentMore(activeCodeMirror);
});
shortcut.add("Ctrl+B", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.moveLineUp(activeCodeMirror);
});
shortcut.add("Ctrl+M", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.moveLineDown(activeCodeMirror);
});
shortcut.add("Alt+Shift+Down", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.copyLineDown(activeCodeMirror);
});
// shortcut.add("Alt+Shift+Up", function() {
// 	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
// 	CodeMirror.commands.copyLineUp(activeCodeMirror);
// });
shortcut.add("Ctrl+J", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.killLine(activeCodeMirror);
});
shortcut.add("Ctrl+U", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.uppperCase(activeCodeMirror);
});
shortcut.add("Ctrl+Shift+U", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.lowerCase(activeCodeMirror);
});
shortcut.add("Ctrl+Y", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.redo(activeCodeMirror);
});
shortcut.add("Tab", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.defaultTab(activeCodeMirror);
});
shortcut.add("Shift+Tab", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.indentAuto(activeCodeMirror);
});
shortcut.add("Alt+Up", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.moveLineUp(activeCodeMirror);
});
shortcut.add("Alt+Down", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.moveLineDown(activeCodeMirror);
});
shortcut.add("Alt+Backspace", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.removeToLineStart(activeCodeMirror);
});
shortcut.add("Ctrl+Delete", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.delWordRight(activeCodeMirror);
});
shortcut.add("Ctrl+Backspace", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.delWordLeft(activeCodeMirror);
});
shortcut.add("Ctrl+Shift+Right", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.selectWordRight(activeCodeMirror);
});
shortcut.add("Ctrl+Shift+Left", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.selectWordLeft(activeCodeMirror);
});
shortcut.add("Alt+Shift+Right", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.selectLineEnd(activeCodeMirror);
});
shortcut.add("Alt+Shift+Left", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.selectLineStart(activeCodeMirror);
});
shortcut.add("Ctrl+Shift+Home", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.selectDocumentStart(activeCodeMirror);
});
shortcut.add("Ctrl+Shift+End", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.selectDocumentEnd(activeCodeMirror);
});
shortcut.add("Ctrl+G", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.goToLine(activeCodeMirror);
});
shortcut.add("Ctrl+P", function() {
	var activeCodeMirror = domtab.getCodeMirror(domtab.activeFile);
	CodeMirror.commands.goToMatchingBrace(activeCodeMirror);
});
shortcut.add("Ctrl+1", function() {
		domtab.getGeneratedCodeMirror(domtab.activeFile).focus();
		control.commentSelection(true);
});

shortcut.add("Ctrl+Shift+1", function() {
		domtab.getGeneratedCodeMirror(domtab.activeFile).focus();
		control.commentSelection(false);
});
shortcut.add("Alt+L", function() {
		domtab.getGeneratedCodeMirror(domtab.activeFile).focus();
		control.foldS();
});
shortcut.add("Alt+Shift+L", function() {
		domtab.getGeneratedCodeMirror(domtab.activeFile).focus();
		control.foldSA();
});
var content = "<script> function (s,e){ for(var i=0; i < 1; i++) test(\"test();a=1\");} </script>\
<script>\
function test(c){  for (var i = 0; i < 10; i++){	          process(\"a.b();c = null;\", 300);}\
}\
</script>\
<table><tr><td>test 1</td></tr><tr><td>test 2</td></tr></table>\
<script> function test() { return 1;} </script>\
<style> .test { font-size: medium; font-family: monospace; }\
</style>";

var content = "function (s,e){ for(var i=0; i < 1; i++) test(\"test();a=1\");}";

shortcut.add("Ctrl+E", function() {
	control.openFileFromServer("myfile", content, "text/javascript");
});
